#ifndef _BALANCE_H
#define _BALANCE_H

#include "motor.h"    //A8 A9 TIM1  A10 A11 A12 A15
#include "pid.h"    



typedef struct
{
    PID_Class speed;//
    PID_Class angle;//
    float output;//
}Balance_CascadePID;

typedef struct 
{
    PID_Class Angle;
    PID_Class Speed;
    float output;
}Balance_ParallelPID;

typedef struct
{
   Balance_CascadePID L;
   Balance_CascadePID R;
} Car_Balance_Class;


extern Car_Balance_Class BC_Car;


int balance_init(void);
void balance_entry(void);
#endif
